package com.yao.club.service;

import com.netease.yidun.sdk.core.utils.StringUtils;
import com.yao.club.entity.UserEntity;
import com.yao.club.entity.dto.InformationCommentLikeRecord;
import com.yao.club.entity.dto.InformationDetail;
import com.yao.club.entity.dto.PostsCommentLikeRecord;
import com.yao.club.entity.dto.SysImg;
import com.yao.club.entity.request.CommentLikeRequestEntity;
import com.yao.club.entity.request.CommentRequestEntity;
import com.yao.club.entity.result.ResponseEntity;
import com.yao.club.entity.result.ResultEntity;
import com.yao.club.entity.vo.InformationCommentVO;
import com.yao.club.mapper.InformationCommentMapper;
import com.yao.club.mapper.InformationMapper;
import com.yao.club.mapper.UserMapper;
import com.yao.club.reposittory.InformationCommentLikeRecordRepository;
import com.yao.club.utils.ResponseUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

public interface InformationCommentService {




    /**
     * 分页获得资讯评论信息
     */
    ResponseEntity<ResultEntity<InformationCommentVO>> pageComment(String postsId, int pageNum, int pageSize);


    List<InformationCommentVO> getCommentsByInformationId(String postsId);


    /**
     * 发布评论
     * @param request
     * @param username
     * @return
     */
    ResponseEntity<Boolean> addComment(CommentRequestEntity request,String username) ;

    /**
     * 发布评论
     * @param commentRequest
     * @param username
     * @return
     */
    ResponseEntity<Boolean> replyComment(CommentRequestEntity commentRequest,String username);

    /**
     * 点赞评论
     * @param commentRequest
     * @param username
     * @return
     */
    ResponseEntity<Boolean> giveLike(CommentLikeRequestEntity commentRequest, String username);

    /**
     * 取消点赞评论
     * @param commentRequest
     * @param username
     * @return
     */
    ResponseEntity<Boolean> giveLikeNo(CommentLikeRequestEntity commentRequest, String username);

    /**
     * 删除帖子
     * @param commentId
     * @param username
     * @return
     */
    ResponseEntity<Boolean> deleteComment(String commentId, String username);
}
